import request from '@/utils/request'

// 新增路线
export function roadAdd(data = {}) {
  return request({
    url: '/workbench/attend-route/create',
    method: 'post',
    data: data
  })
}
// 路线删除
export function roadDel(data = {}) {
  return request({
    url: '/workbench/attend-route/remove',
    method: 'get',
    params: data
  })
}
// 修改路线
export function roadEdit(data = {}) {
  return request({
    url: '/workbench/attend-route/update',
    method: 'post',
    data: data
  })
}
// 路线详情
export function roadDtl(data = {}) {
  return request({
    url: '/workbench/attend-route/detail',
    method: 'get',
    params: data
  })
}
// 路线列表
export function roadList(data = {}) {
  return request({
    url: '/workbench/attend-route/list',
    method: 'get',
    params: data
  })
}


// 路线列表-可根据名称、坐标查找附近路线
export function roadListBearby(data = {}) {
  return request({
    url: '/workbench/attend-route/nearby',
    method: 'get',
    params: data
  })
}
